<template>
  <a-result status="404" title="页面没找到" sub-title="抱歉、当前页面不存在.">
    <template #extra>
      <a-button type="primary" @click="toHome">
       返回首页
      </a-button>
    </template>
  </a-result>
</template>

<script>
import { CURRENT_PATH, CURRENT_SELECT_APP, OPEN_MENU_KEY, SELECT_MENU } from '@/store/mutation-types'

export default {
  name: 'Exception404',
  methods: {
    toHome () {
      this.$store.commit(CURRENT_SELECT_APP, '')
      this.$store.commit(OPEN_MENU_KEY, '')
      this.$store.commit(SELECT_MENU, '')
      this.$store.commit(CURRENT_PATH, '')
      this.$router.push({ path: '/' })
    }
  }
}
</script>
